/*
 * 文 件 名:  LoginServiceProvider.java
 * 创建日期:  2012-9-17
 * 版    权:  Epro Technologies Co., Ltd. Copyright 2011-2012,  All rights reserved
 * 作    者:  hjd008
 */
package com.weipu.common.facade;

import java.util.ArrayList;
import java.util.List;

import com.weipu.common.facade.exception.DxException;
import com.weipu.common.facade.model.AddressModel;
import com.weipu.common.facade.model.CountryModel;
import com.weipu.common.facade.model.OneKeyFilterResponseModel;
import com.weipu.common.facade.model.ReviewlistModel;
import com.weipu.common.facade.model.UserModel;
import com.weipu.common.facade.model.WishModel;
import com.weipu.common.facade.model.config.CacheConfigModel;

/**
 * 用户服务提供者
 * @version [版本号, 2012-9-29]
 * @see [相关类/方法]
 * @since [产品/模块版本]
 * 
 * @author hjd008
 */
public interface UserServiceProvider
{
    /**
     * 注册
      * @param url
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    String register(String email, String userName, String firstName, String lastName, String passWord)
        throws DxException;
    
    /**
     * 
      *  登录
      * @param email
      * @param password
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    UserModel login(String email, String password)
        throws DxException;
    
    /**
     * 
      *  忘记密码
      * @param email
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    boolean forgetPassword(String email)
        throws DxException;
    
    /**
     * 
      *  获取用户信息
      * @param 
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    UserModel getAccountForUser(String customerId,String token)
        throws DxException;
    
    /**
     * 
      *  修改用户信息
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    String updateAccuntForUser(String FirstName, String LastName, short Gender, String Birthday, short Education,
        short MaritalStatus, String CountryCode, List<Short> Hobby, short Income, String customerid,String token)
        throws DxException;
    
    /**
     * 
      *  修改密码
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    int changePassword(String customerId, String oldPwd, String newPwd,String token)
        throws DxException;
    
    /**
     * 
      *  获取所有国家对照表
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    CountryModel allCountry()
        throws DxException;
    
    /**
     * 
      *  获取我的商品评论列表
      * @return  [参数说明]
      * @return String [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
     */
    ArrayList<ReviewlistModel>  cusotmerReviewList(int SKU, long CICID, String userName, int pageIndex, int pageSize,String token)
        throws DxException;
    
//    /**
//      *  获取商品评论列表
//      * @param SKU M
//      * @param CICID M
//      * @param userName M
//      * @param pageIndex O
//      * @param pageSize O
//      * @return  [参数说明]
//      * @return String [返回类型说明]
//      * @exception throws [违例类型] [违例说明]
//      * @see [类、类#方法、类#成员]
//      */
//    String cusotmerReviewList1(int SKU, long CICID, String userName, int pageIndex, int pageSize)
//        throws DxException;
    
    /**
     * 
     *  添加商品到心愿单
     * 
     * @return [参数说明]
     * @return String [返回类型说明]
     * @exception throws [违例类型] [违例说明]
     * @see [类、类#方法、类#成员]
     */
    String addWishlistForUser(int sku, String Source,long customerID,String token)
        throws DxException;
    
    /**
     * 
     *  删除心愿单记录
     * 
     * @return [参数说明]
     * @return String [返回类型说明]
     * @exception throws [违例类型] [违例说明]
     * @see [类、类#方法、类#成员]
     */
    String delWishlistForUser(String username, int sku,String token)
        throws DxException;
    
    /**
     * 获取用户心愿单总数
     * 
     * @return [参数说明]
     * @return String [返回类型说明]
     * @exception throws [违例类型] [违例说明]
     * @see [类、类#方法、类#成员]
     */
    String getCountWishlistForUser(String username,String token)
        throws DxException;
    
    /**
     * 获取用户心愿单列表
     * 
     * @return [参数说明]
     * @return String [返回类型说明]
     * @exception throws [违例类型] [违例说明]
     * @see [类、类#方法、类#成员]
     */
    ArrayList<WishModel> wishListInfoForUser(String UserName, String WishSort, int PageIndex, int PageSize,long customerId,String token)
        throws DxException;
    
    /**
      * 获取客户端配置信息
      * @return
      * @throws DxException  [参数说明]
      * @return ArrayList<CacheConfigModel> [返回类型说明]
      * @exception throws [违例类型] [违例说明]
      * @see [类、类#方法、类#成员]
      */
    CacheConfigModel getCacheConfig()
        throws DxException;
    
    /**
     * 新增用户地址
     * @param addressModel
     * @return
     * @throws DxException
     */
    String AddAddress(AddressModel addressModel) throws DxException;
    
    /**
     * 删除用户地址
     * @param addressModel
     * @return
     * @throws DxException
     */
    String DeleteAddress(long addressId,long customerId,String token) throws DxException;
    
    /**
     * 获取用户地址
     * @param addressModel
     * @return
     * @throws DxException
     */
    List<AddressModel> GetAddresses(long CustomerID,int AddressType,int PageIndex,int PageSize,String token) throws DxException;
    
    /**
     * 更新用户地址
     * @param addressModel
     * @return
     * @throws DxException
     */
    String UpdateAddress(AddressModel addressModel) throws DxException;
    
    /**
     * 设置默认收获地址
     * @param addressId
     * @return
     * @throws DxException
     */
    String ChooseDefaultAddress(long addressId,long customerId,String token) throws DxException;
    
    /**
     * 获取默认地址
     * @param customerId
     * @param addressType
     * @return
     * @throws DxException
     */
    AddressModel GetDefaultAddress(long customerId,int addressType,String token)throws DxException;
    
    /**
     * @创建：Tony 2016-3-29下午3:10:52
     * @描述：获取用户设置的过滤设置信息
     * @param token
     * @param customerID
     * @return
     * @throws DxException
     */
    OneKeyFilterResponseModel getCustomerFilter(String token,long customerID)throws DxException;
    
    /**
     * @创建：Tony 2016-3-29下午4:19:29
     * @描述：保存用户一键过滤的设置
     * @param token
     * @param customerID
     * @param isFilter
     * @param blackCategoryIds 黑名单(不显示的品类) 多个用-号隔开
     * @return
     * @throws DxException
     */
    OneKeyFilterResponseModel saveCustomerFilter(String token,long customerID,boolean isFilter,String blackCategoryIds)throws DxException;
    
    /**
     * @创建：Tony 2016-4-8下午4:42:14
     * @描述：保存用户一键过滤状态
     * @param token
     * @param customerID
     * @param isFilter
     */
    void SaveCustomerIsFilter(String token,long customerID,boolean isFilter)throws DxException;
}
